<template>
  <el-dialog :close-on-click-modal="false" :visible="upgradeDetailsFlag" class="zdy-dialog" width="40%"
             append-to-body
             custom-class="tree-cesium-container"
             title="详情" :before-close="handleCloseDialog">

    <div v-if="editTableRowSub&&editTableRowSub.upgradeLogs">
      <el-timeline :reverse="reverse">
        <el-timeline-item
            v-for="(activity, index) in editTableRowSub.upgradeLogs"
            :key="index"
            :timestamp="activity.logDatetime">
          {{activity.content}}
        </el-timeline-item>
      </el-timeline>
    </div>


<!--    暂无数据-->
    <div class="emptyBox" v-if="editTableRowSub.upgradeLogs&&!editTableRowSub.upgradeLogs.length">
      <img src="@/assets/common/img/nodataIcon.png" alt="" />
      <!--暂无数据-->
      <div>{{this.i18n.t('No data available')}}</div>
    </div>
  </el-dialog>
</template>

<script>
export default {
  name: "upgradeDetails",
  components: {},
  props: {
    upgradeDetailsFlag:{
      type: Boolean,
      default: false
    },
    editTableRowSub: {
      type: Object,
      defautl: () => {
        return {}
      }
    }
  },
  watch: {

  },
  data() {
    return {
      reverse:true
    }
  },
  mounted() {
    // this.editTableRowSub.upgradeLogs=[]
    console.log(this.editTableRowSub);
  },
  methods: {
    /**
     * @description  关闭弹窗事件
     * @return not
     * @author xiongyi 2022-06-29 16:48:08
     **/
    handleCloseDialog() {
      this.$emit('update:upgradeDetailsFlag', false);
      // if (this.fileName) {
      //   this.$refs.upload.clearFiles()
      // }
    },
  }
}
</script>

<style scoped lang="scss">

</style>
<style>
/*.tree-cesium-container .el-dialog__header {*/
/*  padding: 0px;*/
/*}*/
.tree-cesium-container .el-dialog__headerbtn {
  top: 10px;
  right: 10px;
}
</style>
